package org.example.myleet.p997;

import org.example.myleet.Utils.Assert;
import org.example.myleet.Utils.Parser;

public class Main {
    public static void main(String[] args) {
        Solution solution = new Solution();
        Assert.isTrue(2 == solution.findJudge(2, Parser.parse("[[1,2]]")));
        Assert.isTrue(3 == solution.findJudge(3, Parser.parse("[[1,3],[2,3]]")));
        Assert.isTrue(-1 == solution.findJudge(3, Parser.parse("[[1,3],[2,3],[3,1]]")));
        Assert.isTrue(-1 == solution.findJudge(3, Parser.parse("[[1,2],[2,3]]")));
        Assert.isTrue(3 == solution.findJudge(4, Parser.parse("[[1,3],[1,4],[2,3],[2,4],[4,3]]")));
        Assert.isTrue(1 == solution.findJudge(1, Parser.parse("[]")));
        Assert.isTrue(-1 == solution.findJudge(2, Parser.parse("[]")));
    }
}
